#ifndef __INCreSocketh
#define __INCreSocketh
#ifdef _WIN32
#include<io.h>
#include <winsock2.h>
#include <ws2tcpip.h>
typedef SOCKET SocketHandle;
#define INVALID_SOCKET_HANDLE INVALID_SOCKET
#define SOCKET_ERROR_CODE WSAGetLastError()
#define CLOSE_SOCKET      closesocket
#else
#include <sys/socket.h>
#include <netinet/in.h>
#include <arpa/inet.h>
#include <unistd.h>
#include <fcntl.h>
#include <errno.h>
typedef int SocketHandle;
#define INVALID_SOCKET_HANDLE -1
#define SOCKET_ERROR_CODE errno
#define CLOSE_SOCKET      ::close
#endif
#endif